/*
 * ActuatingLoop.hpp
 *
 *  Created on: Sep 4, 2009
 *      Author: zurihopper
 */

#ifndef ACTUATINGLOOP_HPP_
#define ACTUATINGLOOP_HPP_

#include <vector>
#include <ecl/threads.hpp>
#include "./Loop.hpp"

using std::vector;
//using Octopus::BoardSetup::TitechBoard;
using ECL::Threads::Mutex;
using Octopus::ToolKit::Log::Logger;

namespace Octopus {

namespace MainLoop {

class ActuatingLoop : protected Loop {

public:
	static Loop* getInstance(Logger * = NULL);
	void remove(void);

	void start(void);
	bool stop(void);

	bool finished(void);

	bool changeSetPoints(vector<double>);


private:
//	static ControlLoop *controlLoop;
//	TitechBoard *titechBoard;
	Mutex mutex;
	Mutex setPointMutex;

	vector<int> sensorValues;
	vector<int> motorCommands;
	vector<double> setPoints;


	ActuatingLoop(Logger * = NULL);
	virtual ~ActuatingLoop();
};




}

}

#endif /* ACTUATINGLOOP_HPP_ */
